
-- a procedure to get tools by house and its type
-- it will a table of tools
IF OBJECT_ID('getTools') IS NOT NULL
	BEGIN
		DROP PROCEDURE getTools;
	END
GO
CREATE PROCEDURE getTools
	@HouseId		VARCHAR(20),
	@ToolType		VARCHAR(50)
AS
BEGIN
	SELECT toolid, toolname FROM tool WHERE houseid=@HouseId
	AND	tooltype=@ToolType AND isdeleted=0;
END
GO

